package org.zhaijisong.pojo;

public class Line {
    private Integer id;
    private Integer initAddress;
    private Integer finalAddress;
    private Integer distance;

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Integer getInitAddress() {
        return initAddress;
    }

    public void setInitAddress(Integer initAddress) {
        this.initAddress = initAddress;
    }

    public Integer getFinalAddress() {
        return finalAddress;
    }

    public void setFinalAddress(Integer finalAddress) {
        this.finalAddress = finalAddress;
    }

    public Integer getDistance() {
        return distance;
    }

    public void setDistance(Integer distance) {
        this.distance = distance;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        Line line = (Line) o;

        if (id != null ? !id.equals(line.id) : line.id != null) return false;
        if (initAddress != null ? !initAddress.equals(line.initAddress) : line.initAddress != null) return false;
        if (finalAddress != null ? !finalAddress.equals(line.finalAddress) : line.finalAddress != null) return false;
        if (distance != null ? !distance.equals(line.distance) : line.distance != null) return false;

        return true;
    }

    @Override
    public int hashCode() {
        int result = id != null ? id.hashCode() : 0;
        result = 31 * result + (initAddress != null ? initAddress.hashCode() : 0);
        result = 31 * result + (finalAddress != null ? finalAddress.hashCode() : 0);
        result = 31 * result + (distance != null ? distance.hashCode() : 0);
        return result;
    }
}
